import request from '@/utils/request'

export function couponList(page, size) {
  return request({
    url: '/coupon/list',
    method: 'get',
    params: {page, size}
  })
}

export function couponAdd(data) {
  return request({
    url: '/coupon/createOrUpdate',
    method: 'post',
    data
  })
}

export function findById(id) {
  return request({
    url: '/coupon/getCouponInfo',
    method: 'get',
    params: {id}
  })
}

export function sonCoupon(data) {
  return request({
    url: '/userCoupon/son',
    method: 'post',
    data
  })
}

